using UnityEngine;

public static class F
{
	public static float PowNatural(float n, int exp)
	{
		float num = n;
		exp = Mathf.Max(exp, 0);
		if (exp == 0)
		{
			num = 1f;
		}
		else if (exp == 2)
		{
			num = n * n;
		}
		else if (exp > 2)
		{
			for (int i = 0; i < exp; i++)
			{
				if (i > 0)
				{
					num *= n;
				}
			}
		}
		return num;
	}

	public static float MaxAbs(params float[] nums)
	{
		float num = 0f;
		for (int i = 0; i < nums.Length; i++)
		{
			if (Mathf.Abs(nums[i]) > Mathf.Abs(num))
			{
				num = nums[i];
			}
		}
		return num;
	}
}
